package com.gmu.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import java.util.Date;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import java.io.Serializable;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * 核酸预约
 * </p>
 *
 * @author testjava
 * @since 2022-07-24
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@ApiModel(value="TblOrder对象", description="核酸预约")
public class TblOrder implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "序列号")
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty(value = "用户id")
    private Integer userId;

    @ApiModelProperty(value = "身份证号")
    private String idNumber;

    @ApiModelProperty(value = "预约开始时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "Asia/Shanghai")//设置查询数据库得到的时间格式，否则是这种格式的 2022-05-29T09:43:52.000+00:00
    private Date orderBeginTime;

    @ApiModelProperty(value = "预约结束时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "Asia/Shanghai")//设置查询数据库得到的时间格式，否则是这种格式的 2022-05-29T09:43:52.000+00:00
    private Date orderEndTime;

    @ApiModelProperty(value = "出发地点")
    private String leaveAddress;

    @ApiModelProperty(value = "预约活动id")
    private Integer beSampleId;

    @ApiModelProperty(value = "活动id")
    private Integer activitiesId;

    @ApiModelProperty(value = "预约状态-0失败-1待检测-2已检测")
    private Integer status;

    @ApiModelProperty(value = "经度")
    private String longitude;

    @ApiModelProperty(value = "纬度")
    private String latitude;

    @ApiModelProperty(value = "修改预约时，需要传改前的id")
    @TableField(exist = false)
    private Integer oldBeSampleId;

    @ApiModelProperty(value = "用户")
    @TableField(exist = false)
    private TblUser tblUser;

    @ApiModelProperty(value = "核酸检测活动表")
    @TableField(exist = false)
    private TblActivities tblActivities;

    @ApiModelProperty(value = "活动地点表")
    @TableField(exist = false)
    private TblActivitiesAddress tblActivitiesAddress;

    @ApiModelProperty(value = "采样地点表")
    @TableField(exist = false)
    private TblSampleAddress tblSampleAddress;

    @ApiModelProperty(value = "被采样单位活动表")
    @TableField(exist = false)
    private BeSampleUnitsActivities beSampleUnitsActivities;

}
